$(document).ready(function () {
    var id= UrlParm.parm("id");
    getUserInfo(id);

})

/*获取用户信息*/
function getUserInfo(id) {
    $.ajax({
        "url":"../userlogin.do",
        "type":"POST",
        "data":{"method":"review"},
        "dataType":"json",
        "success":function(result){
            $(".picture").append(showPicture(result));
            $(".info").append(showInfo(result));
        }
    })
}

function showPicture(user) {
    return $("<img src='"+user.photoPath+"'>");
}
function  showInfo(user) {
    return $("<p>"+user.name+"</p>" +
        "<p>绑定手机："+user.phone+"</p>" +
        "<p>绑定邮箱："+user.email+"</p>" +
        "<p><a href='updateuser.html?id="+user.id+"'>修改信息</a></p>");
}

